In recent years, storage systems utilize solid state drives (SSD) as storage devices for storing data. An SSD includes a flash memory, which is a non-volatile memory, as a data storage unit and is superior to hard disk drives (HDD) in terms of the performance of random access to stored data and the like.
A flash memory includes a plurality of blocks as data storage areas, and each block further includes a plurality of pages. Write of data to a flash memory and read of data from a flash memory are executed on a page basis. Note that in flash memories, a page to which data is already written is not overwritable with other data. Thus, storing new data into a page in which data is already stored involves erasing the data in the page and then storing the new data.
Also, erasure of data stored in a flash memory is performed only on a block basis. For example, in a case where valid data is stored in a first page included in a first block and unrequested data is stored in a second page included in the first block, it is impossible to selectively erase only the unrequested data stored in the second page. Then, if the free space in the flash memory is low due to the unrequested data, the unrequested data may be erased to obtain a sufficient empty space by backing up the valid data stored in the first page to a second block and then erasing the data in the entire first block.
Also, in a case where an information processing apparatus such as a host server writes pieces of data with discontinuous logical addresses to an SSD, the pieces of data are stored scatteredly in the SSD, which may causes a decrease in free space. For this situation, garbage collection has been known as a process to increase the free space. Garbage collection generally starts to be executed when the SSD detects that the free space in its memory has reached or fallen below a predetermined value. Note that the “free space” in this specification is a value obtained by subtracting a logical capacity which is a capacity available for information processing apparatuses such as host servers from the physical capacity of the SSD, and corresponds to the capacity of an area called spare area. In execution of garbage collection, a process such as temporary back up of data is performed using the spare area. The related techniques are disclosed in, for example, Japanese Laid-open Patent Publication Nos. 2014-059850 and 7-234763 are related art documents.